import request from '@/utils/request'

// 登录方法
export function login(username, loginPwd, codeObject, category) {
  return request({
    url: '/index/login',
    method: 'post',
    data: {
      username,
      loginPwd,
      codeObject,
      category
    }
  })
}

// 获取用户详细信息
export function getInfo() {
  return request({
    url: '/index/info',
    method: 'get'
  })
}

// 退出方法
export function logout() {
  return request({
    url: '/index/logout',
    method: 'post'
  })
}

